package com.xdf.whiteaccount.service;
import com.xdf.whiteaccount.utils.Example;
import com.xdf.whiteaccount.entity.FabContractDetail;
import java.util.List;

/**
 * @Description : 服务层接口，由代码生成器自动生成
 * @Author : chanchaw
 * @Date : 2023-8-15 12:57:20
 */
public interface FabContractDetailService {
    FabContractDetail insert(FabContractDetail record);

    FabContractDetail insertSelective(FabContractDetail record);

    List<FabContractDetail> multiInsert(List<FabContractDetail> list);

    int updateByPrimaryKey(FabContractDetail record);

    int updateByPrimaryKeySelective(FabContractDetail record);

    // 根据主键删除
    int deleteByPrimaryKey(Long id);
    // 根据主键查询
    FabContractDetail selectByPrimaryKey(Long id);
    // 根据主键作废
    int setVoid(Long id);
    // 是明细表则有字段 parent_id
    List<FabContractDetail> selectByParentId(Long parentId);

    List<FabContractDetail> selectAll();

    FabContractDetail save(FabContractDetail record);
    List<FabContractDetail> multiSave(List<FabContractDetail> list);

    //================= 下面是默认方法 ==================
    default void checkEntityNotNull(FabContractDetail record){// 返回true表示合法，可继续
        if(record == null) throw new RuntimeException("无法保存空数据！");
    }

    default FabContractDetail fullFill(FabContractDetail record){
        return record;
    }

    default void doBeforeInsert(FabContractDetail record){}
    default void doAfterInsert(FabContractDetail record){}
    List<FabContractDetail> selectByExample(Example<FabContractDetail> example);
    FabContractDetail moveBill(Integer id, String moveBillFlag);
    //=================以上是自动生成的代码，自定义代码请写在下面==================
}